home *** CD-ROM | disk | FTP | other *** search
/ Windows News 2010 Summer - Disc 1 / WN_Ete2010_CD1.iso / Onglet5 / Weezo / Weezo setup.exe / {code_appDir} / www / help.php < prev    next >
PHP Script  |  2010-05-19  |  3KB  |  64 lines

  1. <?php
  2. /**
  3.  * Help messages
  4.  *
  5.  * PHP version 5
  6.  *
  7.  * LICENSE: This source file is subject to version 3.0 of the PHP license
  8.  * that is available through the world-wide-web at the following URI:
  9.  * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
  10.  * the PHP License and are unable to obtain it through the web, please
  11.  * send a note to license@php.net so we can mail you a copy immediately.
  12.  *
  13.  * @category   NA
  14.  * @package    NA
  15.  * @author     Nicolas Bruley / Peer 2 World <contact@weezo.net>
  16.  * @copyright  2005-2009 Nicolas Bruley / Peer 2 World
  17.  * @license    http://www.php.net/license/3_0.txt  PHP License 3.0
  18.  * @version    CVS: $Id:$
  19.  * @link       http://www.weezo.net
  20.  * @since      File available since Release 1.0.0
  21.  */
  22.  
  23. require_once(INCLUDE_DIR.'outputFunctions.php');
  24.  
  25. // XML header
  26. cfAsyncHeader();
  27. $innerHTML="";
  28. if(isset($_POST['hId'])){
  29.     $innerHTML.='<div style="position:absolute; display:block; z-index:1000;" class="helpFrame" id="helpFrame" onmouseover="if(window.disableInputs) disableInputs()" onmouseoout="if(window.enableInputs) enableInputs()">';
  30.     $innerHTML.='<div style="position:absolute;left:0px;top:0px; width:100%; height:100%; display:block" class="helpBg"></div>';
  31.     $innerHTML.=outThemeImage(outIcon('bulb'),false,false,'position:absolute;left:8px;top:9px;');
  32.     $innerHTML.='<div id="helpCaptionDiv" style="padding:10px;text-align:left; position:relative">'.cfCaption($_POST['hId']).'</div>';
  33.     $innerHTML.=outImage(outIcon('closeM'),false,'onclick="maskHide(); if(window.dd) {dd.elements[\'helpFrame\'].hide();dd.elements[\'helpFrame\'].del()} else dgi(\'helpDiv\').innerHTML=\'\';wl.removeKeycodeListener(D)" title="'.cfCaption('genClose').'"','position:absolute;right:-12px;top:-12px;cursor:pointer');
  34.     $innerHTML.='<input style="width:1;height:1;overflow:hidden;border:0;margin:0;padding:0" id="selInput">';
  35.     $innerHTML.='</div>';
  36.  
  37.     $js='maskShow(false,true);';
  38.     $js.='if(!dgi("helpDiv")) {var helpDiv=D.createElement("div");';
  39.     $js.='var helpDivId=D.createAttribute("id");';
  40.     $js.='helpDivId.nodeValue="helpDiv";';
  41.     $js.='helpDiv.setAttributeNode(helpDivId);';
  42.     $js.='D.body.appendChild(helpDiv);}';
  43.  
  44.     $js.='dgi("helpDiv").innerHTML=\''.str_replace("'", "\\'",$innerHTML).'\';';
  45.     $js.='dgi("helpFrame").style.height=(dgi("helpCaptionDiv").offsetHeight + 20)+"px";';
  46.     $js.='maskMoveAbove(dgi("helpFrame"));';
  47.     $js.='wl.setKeycodeListener(D,function(kc){maskHide(); if(window.dd) {dd.elements[\'helpFrame\'].hide();dd.elements[\'helpFrame\'].del()} else dgi(\'helpDiv\').innerHTML=\'\';wl.removeKeycodeListener(D)});dgi("selInput").focus();';
  48.  
  49.     if(cfGetBrowser()=='ie'){
  50.         $js.='dgi("helpFrame").style.top=(D.body.offsetHeight-200)/2;';
  51.         $js.='dgi("helpFrame").style.left=(D.body.offsetWidth-400)/2;';
  52.     }
  53.     else{
  54.         $js.='dgi("helpFrame").style.top=(window.innerHeight-300)/2;';
  55.         $js.='dgi("helpFrame").style.left=(window.innerWidth-400)/2;';
  56.     }
  57.     if(cfGGetVar('allowDragNDrop')) $js.='if(W.dd && dd.elements["helpFrame"]==undefined) {ADD_DHTML("helpFrame"+NOTDROPPABLE+ISICON)}';
  58.     echo cfAsyncXMLJSaction($js);
  59. }
  60.  
  61. echo cfAsyncFooter();
  62. exit;
  63. ?>
  64.